home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-04 / 422mods.zip / KH01A.422 < prev    next >
Text File  |  1993-03-10  |  3KB  |  114 lines

  1. KH01A.MOD - Allows you to have //NEWS with 3 news files
  2. King Hippo  #1 @4652
  3. Sun Mar 07 17:56:12 1993
  4. ┌───────────────────────────────────────────────────────────────────────────┐
  5. │ MOD NAME      : KH01A.MOD       MOD AUTHOR: King Hippo                    │
  6. │ DiFFiCULTY    : 2/10            DATE      : Feb. 7, 1993.                 │
  7. │ WWiV VERSiON  : 4.22                                                      │
  8. │ FiLES AFFECTED: MISCCMD.C,  BBS.C                                         │
  9. │ DESCRiPTiON   : Allows you to have a //NEWS command, which will display 3 │
  10. │                 news files.  1NEWS, 2NEWS, 3NEWS!  But can have more...   │
  11. └───────────────────────────────────────────────────────────────────────────┘
  12.  
  13. LONG DESCRiPTiON─────
  14.  
  15.    There are couple of things that you can set to your own needs and likes..
  16. First of all any lines that have, PL(".....");  can be put into BBS.STR
  17. and instead of PL("....text...");, you can put PL(5,GET_STRING(1000));  or
  18. whatever the number of that string is... But I highly suggest you leave it
  19. this way...
  20.    The modification will display 1NEWS.ANS to ansi users and 1NEWS.MSG to
  21. non ansi users...  1NEWS is displayed if a user hits 1, 2NEWS it 2...etc.
  22. You can change/add/delete the choices as you please.. But remmber to change
  23. CH=ONEK("123"); to whatever the CASE statements are after... On with the mod.
  24.  
  25.  
  26. Legend         :
  27.  
  28. /* ADD    */  ADD this line
  29. /* DELETE */  DELETE this line  (or comment out with // or /* blah blah */)
  30. /* CHANGE */  CHANGE this line
  31. /* SEARCH */  SEARCH for this line
  32.  
  33.  
  34.  
  35. Mod:
  36.  
  37. STEP  --- 1 ---
  38.  
  39.  
  40. Back up your source...
  41. PKZIP SOURCE -A *.C -A *.H -A *.MAK
  42.  
  43.  
  44. STEP  --- 2 ---
  45.  
  46.  
  47. Open up MISCCMD.C ....
  48.  
  49.  
  50. /* SEARCH */  lseek(f,((long) ii)*sizeof(votingrec),SEEK_SET);
  51. /* SEARCH */  write(f,(void *)&v,sizeof(votingrec));
  52. /* SEARCH */  nl();
  53. /* SEARCH */  nl();
  54. /* SEARCH */}
  55.  
  56. /*************** NEWS DISPLAY...  RIGHT AFTER THOSE FEW LINES ********/
  57.  
  58. void news(void)
  59. {
  60.  
  61.   char ch;
  62. //***************
  63. // THESE 3 LINES OF TEXT CAN BE PUT INTO YOUR BBS.STR WITH ESM..
  64. // TO DO THAT..  YOU SHOULD REMMBER THE 4 LINE NUMBERS... AND THEN
  65. // PUT PL(GET_STRING(xxxxx));  WHERE xxxx IS THE NUMBER OF THE STRING...
  66. //***************
  67. if (!incom)
  68. pl("8N7E9W1S 1Di9sp7la8y 3Mod by King Hippo 1@4661\n");
  69.  
  70. pl("21. 1Today's News");
  71. pl("22. 1Yesterday's News");
  72. pl("23. 1Services and sales");
  73. //***************
  74. nl();
  75. prt(2,"Which (1-3),? ");
  76.  
  77.       ch=onek("123");
  78.       switch(ch) {
  79.    case '1':
  80.      printfile("1NEWS");
  81.      break;
  82.    case '2':
  83.      printfile("2NEWS");
  84.      break;
  85.    case '3':
  86.      printfile("3NEWS");
  87.      break;
  88.              }
  89.  
  90. /********************** NEWS DISPLAY BY KING HIPPO 1@4661 ENDS HERE ********/
  91.  
  92.  
  93. STEP  --- 3 ---
  94.  
  95.  
  96. Open up BBS.C and search for VOID MAINMENU.... now in it search for whatever
  97. i tell you below to search for.... <grin>...
  98.  
  99.  
  100. /* SEARCH */  /*************************************************/
  101. /* ADD    */  if ((strcmp(s,"NEWS")==0) &&(actsl>10))
  102. /* ADD    */    news();
  103. /* SEARCH */  if ((strcmp(s,"UPLOAD")==0) && (actsl>10))
  104.  
  105.  
  106.  
  107.  
  108.     There, now that wasn't too bad, now was it?  If you have a mod you
  109. would like me to install for you, just give me your registration #, so I
  110. can check if you are truly registered...  and the mod itself, and I will do
  111. it for you, for FREE!!  See ya,
  112.  
  113.  
  114. Earth Corruption Error:  Start new race (non-human possibly) [Y/N]6_0